<template>
    <div>
 <div id="nav">
      <ul class="ul">
      <router-link tag="li" :exact=true to="/">Home</router-link> 
      <router-link tag="li"  to="/about">关于我们</router-link>
      <router-link tag="li"  :to="{name:'Leamsc'}">在线留言</router-link> 
      <router-link tag="li"  :to="{name:'Product'}">生产展示</router-link>
      <router-link tag="li"  :to="{name:'Connect'}">联系我们</router-link> 
      <router-link tag="li"  :to="{name:'Newspaper'}">新闻报道</router-link>
      <router-link tag="li"  :to="{name:'Login'}">登录</router-link>
      </ul>
    </div>
    </div>
</template>

<script>
    export default {
        name:'Nav',
        methods:{
         
        }
    }
</script>

<style  lang="less">
.ul{
  padding: 0;
  list-style: none;
  width: 1000px;
  height: 40px;
  display: flex;
  // background-color: thistle;
  &>li{
    cursor: pointer;
    width:16%;
    line-height: 40px;
    background-color: #42b983;
    color: white;
    // text-align: center;
  &:hover,&.router-link-exact-active,&.router-link-active{
    background-color: white;
    color:#42b983;
  }
  }
}
#nav {
  padding: 30px;

  a {
    font-weight: bold;
    text-decoration: none;
    color: #2c3e50;

    &.router-link-exact-active {
      color: #42b983;
    }

  }
}
</style>